$(document).ready(function() {
	$(".option").click(function() {
		$(this).fadeTo("slow", 0.5).fadeTo("fast", 1.0);
		var type = $(this).attr("id");
		var wait=setInterval(function(){
	        if(!$(".option").is(":animated")){
	            clearInterval(wait);
	            if (type == "article") {
	            	window.location = "/CyanZhong/article-waterfall?type=all";
	            } else if (type == "god"){
	            	window.location = "/CyanZhong/login.jsp";
	            } else if (type == "album") {
	            	window.location = "/CyanZhong/album.jsp";
	            }
	        }
	    },200);
	});
});

$(document).ready(function() {
	$('.option').wrapInner('<span class="hover"></span>').css('textIndent','0').each(function () {
		$('span.hover').css('opacity', 0).hover(function () {
			$(this).stop().fadeTo(650, 1);
		}, function () {
			$(this).stop().fadeTo(650, 0);
		});
	});
});